$(document).ready(function(){
	$("div.shareVK a").bind('click',function(e){
		$.post("/common/fix_vk_public.php","",function(){},"json");
	});
});

var VK_Share_button = function(obj){
	return VK.Share.button(
		{
			url: (obj.url ? obj.url : Dictionary.translate('lang_vk_share_button_url')),
			title: (obj.title ? obj.title : Dictionary.translate('lang_vk_share_button_title')),
			description: (obj.description ? obj.description : Dictionary.translate('lang_vk_share_button_description')),
			image: (obj.image ? obj.image : Dictionary.translate('lang_vk_share_button_img')),
			noparse: (obj.noparse ? obj.noparse : true)
		},
		{
			type: (obj.type ? obj.type : 'round_nocount'),
			text: (obj.text ? obj.text : Dictionary.translate('lang_vk_share_button_text'))
		}
	)	
};
